using Godot;
using System;
[GlobalClass]


public partial class CollectTask : Tasks
{
	[Export]
	public string taskItem;
	[Export]
	public int number;
	// Called when the node enters the scene tree for the first time.
	public override void _Ready()
	{
		this.CurrentType = Type.COLLECT;
		var Game = GetNode<Game>("/root/Game");
		MessageManager messageManager = Game.get_message_manager();
		messageManager.ItemAdd += TaskComplete;
	}

	// Called every frame. 'delta' is the elapsed time since the previous frame.
	public override void _Process(double delta)
	{
	}

	public void TaskComplete(Item item)
	{
		GD.Print("拾取道具");
	}
}
